package ace.module.security.api.annotation;

import ace.module.security.api.constant.SecurityConstant;
import java.lang.annotation.*;
import org.springframework.security.access.prepost.PreAuthorize;

/**
 * @author caspar
 * @date 2023/3/23 15:09 是否认证的应用对象
 */
@Target({ElementType.METHOD, ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Documented
@PreAuthorize("@securityService.hasAuthority('" + SecurityConstant.OAUTH2_SCOPE_APPLICATION + "')")
public @interface PreAuthorizeIsApplication {}
